package com.hzlx.plans.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.core.annotation.Excel;
import com.ruoyi.common.core.web.domain.BaseEntity;

/**
 * 设备保养计划对象 mes_maintenance_plans
 * 
 * @author ruoyi
 * @date 2025-06-30
 */
public class MaintenancePlans extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 保养计划ID */
    private Integer planId;

    /** 关联设备ID */
    @Excel(name = "关联设备ID")
    private String equipmentId;

    /** 保养计划名称 */
    @Excel(name = "保养计划名称")
    private String planName;

    /** 计划类型：定期/状态保养/故障维修 */
    @Excel(name = "计划类型：定期/状态保养/故障维修")
    private String planType;

    /** 频率类型 */
    @Excel(name = "频率类型")
    private String frequencyType;

    /** 频率值（如：每周1次，或每2000小时） */
    @Excel(name = "频率值", readConverterExp = "如=：每周1次，或每2000小时")
    private Long frequencyValue;

    /** 下次保养到期时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "下次保养到期时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date nextDueDate;

    /** 预计工时（小时） */
    @Excel(name = "预计工时", readConverterExp = "小=时")
    private BigDecimal expectedDurationHours;

    /** 是否激活 */
    @Excel(name = "是否激活")
    private Integer isActive;

    /** 创建人ID */
    @Excel(name = "创建人ID")
    private String createdBy;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createdAt;

    /** 最后更新时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "最后更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date updatedAt;

    public Integer getPlanId() {
        return planId;
    }

    public void setPlanId(Integer planId) {
        this.planId = planId;
    }

    public void setEquipmentId(String equipmentId)
    {
        this.equipmentId = equipmentId;
    }

    public String getEquipmentId() 
    {
        return equipmentId;
    }

    public void setPlanName(String planName) 
    {
        this.planName = planName;
    }

    public String getPlanName() 
    {
        return planName;
    }

    public void setPlanType(String planType) 
    {
        this.planType = planType;
    }

    public String getPlanType() 
    {
        return planType;
    }

    public void setFrequencyType(String frequencyType) 
    {
        this.frequencyType = frequencyType;
    }

    public String getFrequencyType() 
    {
        return frequencyType;
    }

    public void setFrequencyValue(Long frequencyValue) 
    {
        this.frequencyValue = frequencyValue;
    }

    public Long getFrequencyValue() 
    {
        return frequencyValue;
    }

    public void setNextDueDate(Date nextDueDate) 
    {
        this.nextDueDate = nextDueDate;
    }

    public Date getNextDueDate() 
    {
        return nextDueDate;
    }

    public void setExpectedDurationHours(BigDecimal expectedDurationHours) 
    {
        this.expectedDurationHours = expectedDurationHours;
    }

    public BigDecimal getExpectedDurationHours() 
    {
        return expectedDurationHours;
    }

    public void setIsActive(Integer isActive) 
    {
        this.isActive = isActive;
    }

    public Integer getIsActive() 
    {
        return isActive;
    }

    public void setCreatedBy(String createdBy) 
    {
        this.createdBy = createdBy;
    }

    public String getCreatedBy() 
    {
        return createdBy;
    }

    public void setCreatedAt(Date createdAt) 
    {
        this.createdAt = createdAt;
    }

    public Date getCreatedAt() 
    {
        return createdAt;
    }

    public void setUpdatedAt(Date updatedAt) 
    {
        this.updatedAt = updatedAt;
    }

    public Date getUpdatedAt() 
    {
        return updatedAt;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("planId", getPlanId())
            .append("equipmentId", getEquipmentId())
            .append("planName", getPlanName())
            .append("planType", getPlanType())
            .append("frequencyType", getFrequencyType())
            .append("frequencyValue", getFrequencyValue())
            .append("nextDueDate", getNextDueDate())
            .append("expectedDurationHours", getExpectedDurationHours())
            .append("isActive", getIsActive())
            .append("createdBy", getCreatedBy())
            .append("createdAt", getCreatedAt())
            .append("updatedAt", getUpdatedAt())
            .toString();
    }
}
